package org.xzx.cloud.ad.dao;

import org.springframework.data.jpa.repository.JpaRepository;
import org.xzx.cloud.ad.entity.AdPlan;
import org.xzx.cloud.ad.entity.AdUnit;

import java.util.List;

/**
 * 推广单元
 *
 * @author xzx
 */
public interface AdUnitRepository extends JpaRepository<AdUnit, Long> {

    AdUnit findByPlanIdAndUnitName(Long planId, String unitName);

    List<AdUnit> findAllByUnitStatus(Integer unitStatus);
}
